Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[14.0][MIG] l10n_it_website_portal_fatturapa #2520

Merged

Conversation

Borruso
Copy link
Contributor

@Borruso Borruso commented Nov 20, 2021

Migration l10n_it_website_portal_fatturapa from 12.0 to 14.0

Dipendenze l10n_it_website_portal_fiscalcode, l10n_it_website_portal_ipa

--
Confermo di aver firmato il CLA https://odoo-community.org/page/cla e di aver letto le linee guida su https://odoo-community.org/page/contributing

@Borruso Borruso mentioned this pull request Nov 20, 2021
74 tasks
@Borruso Borruso force-pushed the 14.0-mig-l10n_it_website_portal_fatturapa branch from cd19afa to 8fdff13 Compare January 28, 2022 13:12
@matteoopenf
Copy link
Contributor

Ti occorre review?

@Borruso
Copy link
Contributor Author

Borruso commented Feb 4, 2022

Ti occorre review?

Sisi, se puoi fare review va benissimo

Copy link
Member

@SimoRubi SimoRubi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Grazie della PR!
Ho provato il modulo in runboat e mi pare funzionare.
Durante la revisione del codice ho notato un paio di cose: l'unica secondo me da chiarire per poter andare avanti è il controllo rimosso.

if (!$is_pa.length) {
return;
var compute_destinatario_fields_visibility = function () {
if ($is_pa[0].checked) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Come mai questo if è stato invertito?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

problemi con il pre-commit

@@ -5,47 +5,46 @@ odoo.define("l10n_it_website_portal_fatturapa", function (require) {
$(document).ready(function () {
var details_div_selector = ".o_portal_details";
var $details_div = $(details_div_selector);
if (!$details_div.length) {
return $.Deferred().reject("DOM doesn't contain " + details_div_selector);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Come mai questo controllo è stato rimosso?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ora non ricordo devo provare a ri-metterlo e fare dei test

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

il controllo scatta ogni volta che sei in una pagina dove il <div> del portale utente non c'è.
quindi questo controllo è totalmente inutile da questa versione in poi come alle v16.
ecco perché è stato rimosso.

@matteoopenf
Copy link
Contributor

@Borruso per caso la riaggiorni a breve?

@Borruso Borruso force-pushed the 14.0-mig-l10n_it_website_portal_fatturapa branch from 8fdff13 to 0ce49df Compare April 26, 2022 08:33
@matteoopenf
Copy link
Contributor

@SimoRubi sono ok i fix che ha fatto @Borruso ?

@Borruso Borruso force-pushed the 14.0-mig-l10n_it_website_portal_fatturapa branch from 0ce49df to 433e582 Compare September 6, 2022 08:54
Copy link
Contributor

@matteoopenf matteoopenf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

l'abbiamo provato su un sitoweb in fase di test e funziona

@primes2h
Copy link
Contributor

primes2h commented Nov 8, 2022

/ocabot migration l10n_it_website_portal_fatturapa

@OCA-git-bot OCA-git-bot added this to the 14.0 milestone Nov 8, 2022
@matteoopenf
Copy link
Contributor

@SimoRubi qua i fix fatti sono ok? noi lo stiamo usando il modulo senza rilevare problemi

@matteoopenf
Copy link
Contributor

@SimoRubi ci siamo qui?

@sergiocorato
Copy link
Contributor

@SimoRubi ci siamo qui?

@SirTakobi

@SirTakobi
Copy link
Contributor

@SimoRubi ci siamo qui?

@SirTakobi

Me lo segno tra le cose da guardare, ma non credo che riuscirò prossimamente.

La review di @SimoRubi rimarrà così perché l'utente non è più attivo

@matteoopenf
Copy link
Contributor

@SirTakobi ci siamo?

@SirTakobi
Copy link
Contributor

@SirTakobi ci siamo?

Da #2520 (comment) è cambiato solo che ora è tra le cose da guardare 😄

@francesco-ooops
Copy link
Contributor

@Borruso riesci a far ricostruire il runboat?

@Borruso Borruso force-pushed the 14.0-mig-l10n_it_website_portal_fatturapa branch from 433e582 to e24ac96 Compare July 12, 2023 12:28
@Borruso
Copy link
Contributor Author

Borruso commented Jul 12, 2023

@Borruso riesci a far ricostruire il runboat?

fatto rebase vediamo se lo genera

@matteoopenf
Copy link
Contributor

matteoopenf commented Jul 12, 2023 via email

@@ -0,0 +1 @@
Fields `is_pa` and `ipa_code` are not shown in the frontend because Odoo core always supposes that frontend users are individual, and these fields are only meaningful for companies.
Copy link
Contributor

@francesco-ooops francesco-ooops Jul 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Borruso questa sezione si può rimuovere, i due campi sono ora visibili nel portale se l'utente è legato ad un partner di tipo company

Copy link
Contributor

@francesco-ooops francesco-ooops left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Funzionalmente non so dare un giudizio perchè se P.IVA o CF non sono valorizzati da backend l'utente non può attivare la fatturazione elettronica, dato che i due campi non sono editabili per qualche motivo https://recordit.co/m8x6pMTEFs

@FrancescoBallerini
Copy link
Contributor

Funzionalmente non so dare un giudizio perchè se P.IVA o CF non sono valorizzati da backend l'utente non può attivare la fatturazione elettronica, dato che i due campi non sono editabili per qualche motivo https://recordit.co/m8x6pMTEFs

Stavo testando la PR, mi risulta che questo sia un comportamento slegato dalla PR e dovuto al fatto che l'utente abbia già almeno un ordine di vendita confermato/pagato (di cui è stato completato il checkout): quando l'utente esegue un'iscrizione da zero i due campi sono sempre impostabili, anche se in backend risultano non valorizzati.

@francesco-ooops
Copy link
Contributor

@Borruso puoi far ripartire il runboat?

@Borruso Borruso force-pushed the 14.0-mig-l10n_it_website_portal_fatturapa branch from e24ac96 to ef03629 Compare September 13, 2023 14:13
@Borruso
Copy link
Contributor Author

Borruso commented Sep 13, 2023

@Borruso puoi far ripartire il runboat?

fatto

Copy link
Contributor

@francesco-ooops francesco-ooops left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, funzionalmente si comporta come nella 12

data["electronic_invoice_subjected"] = data.get(
"electronic_invoice_subjected", False
)
if data["electronic_invoice_subjected"]:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cosa ne pensi di trasformare questo blocco in

    if data["electronic_invoice_subjected"]:
        data["electronic_invoice_obliged_subject"] = True
        country_italy = request.env.ref('base.it', raise_if_not_found=False)
        country_id = data.get('country_id', False)
        if country_id and country_italy and int(country_id) != country_italy.id:
            data["codice_destinatario"] = "XXXXXXX"
        elif data.get('codice_destinatario') == "XXXXXXX":
            data["codice_destinatario"] = "0000000"

? per via di questo #2520 (comment)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fatto

Copy link
Contributor

@FrancescoBallerini FrancescoBallerini Oct 5, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Borruso Grazie, un ultimo appunto è che si potrebbe importare il codice destinatario standard con "0000000" da qui https://github.com/OCA/l10n-italy/blob/14.0/l10n_it_fatturapa/models/partner.py#L7 , ma non so se ne vale la pena, decidete voi 👍

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Borruso Grazie, un ultimo appunto è che si potrebbe importare il codice destinatario standard con "0000000" da qui https://github.com/OCA/l10n-italy/blob/14.0/l10n_it_fatturapa/models/partner.py#L7 , ma non so se ne vale la pena, decidete voi 👍

puoi aprire una issue per tenerne traccia

monen17 and others added 4 commits October 5, 2023 11:05
FIX l10n_it_website_portal_fatturapa: Cannot read property 'checked' of undefined
when not in /my/home page
Otherwise, when installed directly:

  File "odoo/addons/base/models/ir_model.py", line 1380, in xmlid_lookup
    raise ValueError('External ID not found in the system: %s' % xmlid)
odoo.tools.convert.ParseError: "External ID not found in the system: website.assets_frontend" while parsing None:8, near
<data inherit_id="website.assets_frontend" name="Website Portal Electronic Invoice">
        <xpath expr="." position="inside">
            <script type="text/javascript" src="/l10n_it_website_portal_fatturapa/static/src/js/l10n_it_website_portal_fatturapa.js"/>
        </xpath>
    </data>
@Borruso Borruso force-pushed the 14.0-mig-l10n_it_website_portal_fatturapa branch from dffcafb to 13a03bc Compare October 5, 2023 09:13
data["electronic_invoice_subjected"] = data.get(
"electronic_invoice_subjected", False
)
if data["electronic_invoice_subjected"]:
Copy link
Contributor

@FrancescoBallerini FrancescoBallerini Oct 5, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Borruso Grazie, un ultimo appunto è che si potrebbe importare il codice destinatario standard con "0000000" da qui https://github.com/OCA/l10n-italy/blob/14.0/l10n_it_fatturapa/models/partner.py#L7 , ma non so se ne vale la pena, decidete voi 👍

@sergiocorato
Copy link
Contributor

@Borruso riesci a squashare i commit non rilevanti come diceva @tafaRU ? credo siano questi:

Screenshot(6)

@Borruso Borruso force-pushed the 14.0-mig-l10n_it_website_portal_fatturapa branch from c2e234f to 5d7b489 Compare February 26, 2024 09:10
@Borruso
Copy link
Contributor Author

Borruso commented Feb 26, 2024

@Borruso riesci a squashare i commit non rilevanti come diceva @tafaRU ? credo siano questi:

Screenshot(6)

fatto

@matteoopenf
Copy link
Contributor

merge?

@sergiocorato
Copy link
Contributor

/ocabot merge nobump

@OCA-git-bot
Copy link
Contributor

This PR looks fantastic, let's merge it!
Prepared branch 14.0-ocabot-merge-pr-2520-by-sergiocorato-bump-nobump, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 9d2550c into OCA:14.0 Mar 1, 2024
6 of 7 checks passed
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at d3d8628. Thanks a lot for contributing to OCA. ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.